Integrand size = 32, antiderivative size = 404 \[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=-\frac {B (b c-a d) g^3 n}{2 a c x}+A f^3 x-\frac {1}{2} B \left (\frac {b^2}{a^2}-\frac {d^2}{c^2}\right ) g^3 n \log (x)+\frac {b^2 B g^3 n \log (a+b x)}{2 a^2}-3 B f^2 g n \log (x) \log \left (1+\frac {b x}{a}\right )+\frac {B f^3 (a+b x) \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{b}-\frac {g^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{2 x^2}+\frac {3 (b c-a d) f g^2 (a+b x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{a (c+d x) \left (a-\frac {c (a+b x)}{c+d x}\right )}+3 f^2 g \log (x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )-\frac {B (b c-a d) f^3 n \log (c+d x)}{b d}-\frac {B d^2 g^3 n \log (c+d x)}{2 c^2}+3 B f^2 g n \log (x) \log \left (1+\frac {d x}{c}\right )+\frac {3 B (b c-a d) f g^2 n \log \left (a-\frac {c (a+b x)}{c+d x}\right )}{a c}-3 B f^2 g n \operatorname {PolyLog}\left (2,-\frac {b x}{a}\right )+3 B f^2 g n \operatorname {PolyLog}\left (2,-\frac {d x}{c}\right ) \]
-1/2*B*(-a*d+b*c)*g^3*n/a/c/x+A*f^3*x-1/2*B*(b^2/a^2-d^2/c^2)*g^3*n*ln(x)+ 1/2*b^2*B*g^3*n*ln(b*x+a)/a^2-3*B*f^2*g*n*ln(x)*ln(1+b*x/a)+B*f^3*(b*x+a)* ln(e*((b*x+a)/(d*x+c))^n)/b-1/2*g^3*(A+B*ln(e*((b*x+a)/(d*x+c))^n))/x^2+3* (-a*d+b*c)*f*g^2*(b*x+a)*(A+B*ln(e*((b*x+a)/(d*x+c))^n))/a/(d*x+c)/(a-c*(b *x+a)/(d*x+c))+3*f^2*g*ln(x)*(A+B*ln(e*((b*x+a)/(d*x+c))^n))-B*(-a*d+b*c)* f^3*n*ln(d*x+c)/b/d-1/2*B*d^2*g^3*n*ln(d*x+c)/c^2+3*B*f^2*g*n*ln(x)*ln(1+d *x/c)+3*B*(-a*d+b*c)*f*g^2*n*ln(a-c*(b*x+a)/(d*x+c))/a/c-3*B*f^2*g*n*polyl og(2,-b*x/a)+3*B*f^2*g*n*polylog(2,-d*x/c)
Time = 0.28 (sec) , antiderivative size = 336, normalized size of antiderivative = 0.83 \[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=A f^3 x+\frac {B f^3 (a+b x) \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{b}-\frac {g^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{2 x^2}-\frac {3 f g^2 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )}{x}+3 f^2 g \log (x) \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )-\frac {B (b c-a d) f^3 n \log (c+d x)}{b d}+\frac {3 B f g^2 n ((b c-a d) \log (x)-b c \log (a+b x)+a d \log (c+d x))}{a c}+\frac {B g^3 n \left (\left (-b^2 c^2 x+a^2 d^2 x\right ) \log (x)+b^2 c^2 x \log (a+b x)+a \left (-b c^2+a c d-a d^2 x \log (c+d x)\right )\right )}{2 a^2 c^2 x}-3 B f^2 g n \left (\log (x) \left (\log \left (1+\frac {b x}{a}\right )-\log \left (1+\frac {d x}{c}\right )\right )+\operatorname {PolyLog}\left (2,-\frac {b x}{a}\right )-\operatorname {PolyLog}\left (2,-\frac {d x}{c}\right )\right ) \]
A*f^3*x + (B*f^3*(a + b*x)*Log[e*((a + b*x)/(c + d*x))^n])/b - (g^3*(A + B *Log[e*((a + b*x)/(c + d*x))^n]))/(2*x^2) - (3*f*g^2*(A + B*Log[e*((a + b* x)/(c + d*x))^n]))/x + 3*f^2*g*Log[x]*(A + B*Log[e*((a + b*x)/(c + d*x))^n ]) - (B*(b*c - a*d)*f^3*n*Log[c + d*x])/(b*d) + (3*B*f*g^2*n*((b*c - a*d)* Log[x] - b*c*Log[a + b*x] + a*d*Log[c + d*x]))/(a*c) + (B*g^3*n*((-(b^2*c^ 2*x) + a^2*d^2*x)*Log[x] + b^2*c^2*x*Log[a + b*x] + a*(-(b*c^2) + a*c*d - a*d^2*x*Log[c + d*x])))/(2*a^2*c^2*x) - 3*B*f^2*g*n*(Log[x]*(Log[1 + (b*x) /a] - Log[1 + (d*x)/c]) + PolyLog[2, -((b*x)/a)] - PolyLog[2, -((d*x)/c)])
Time = 0.66 (sec) , antiderivative size = 404, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.062, Rules used = {3008, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \left (f+\frac {g}{x}\right )^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right ) \, dx\) |
\(\Big \downarrow \) 3008 |
\(\displaystyle \int \left (f^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )+\frac {3 f^2 g \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{x}+\frac {3 f g^2 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{x^2}+\frac {g^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{x^3}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {1}{2} B g^3 n \log (x) \left (\frac {b^2}{a^2}-\frac {d^2}{c^2}\right )+\frac {b^2 B g^3 n \log (a+b x)}{2 a^2}+3 f^2 g \log (x) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )+\frac {3 f g^2 (a+b x) (b c-a d) \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{a (c+d x) \left (a-\frac {c (a+b x)}{c+d x}\right )}-\frac {g^3 \left (B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A\right )}{2 x^2}+\frac {B f^3 (a+b x) \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{b}-\frac {B f^3 n (b c-a d) \log (c+d x)}{b d}+\frac {3 B f g^2 n (b c-a d) \log \left (a-\frac {c (a+b x)}{c+d x}\right )}{a c}-\frac {B g^3 n (b c-a d)}{2 a c x}-3 B f^2 g n \operatorname {PolyLog}\left (2,-\frac {b x}{a}\right )-3 B f^2 g n \log (x) \log \left (\frac {b x}{a}+1\right )+A f^3 x-\frac {B d^2 g^3 n \log (c+d x)}{2 c^2}+3 B f^2 g n \operatorname {PolyLog}\left (2,-\frac {d x}{c}\right )+3 B f^2 g n \log (x) \log \left (\frac {d x}{c}+1\right )\) |
-1/2*(B*(b*c - a*d)*g^3*n)/(a*c*x) + A*f^3*x - (B*(b^2/a^2 - d^2/c^2)*g^3* n*Log[x])/2 + (b^2*B*g^3*n*Log[a + b*x])/(2*a^2) - 3*B*f^2*g*n*Log[x]*Log[ 1 + (b*x)/a] + (B*f^3*(a + b*x)*Log[e*((a + b*x)/(c + d*x))^n])/b - (g^3*( A + B*Log[e*((a + b*x)/(c + d*x))^n]))/(2*x^2) + (3*(b*c - a*d)*f*g^2*(a + b*x)*(A + B*Log[e*((a + b*x)/(c + d*x))^n]))/(a*(c + d*x)*(a - (c*(a + b* x))/(c + d*x))) + 3*f^2*g*Log[x]*(A + B*Log[e*((a + b*x)/(c + d*x))^n]) - (B*(b*c - a*d)*f^3*n*Log[c + d*x])/(b*d) - (B*d^2*g^3*n*Log[c + d*x])/(2*c ^2) + 3*B*f^2*g*n*Log[x]*Log[1 + (d*x)/c] + (3*B*(b*c - a*d)*f*g^2*n*Log[a - (c*(a + b*x))/(c + d*x)])/(a*c) - 3*B*f^2*g*n*PolyLog[2, -((b*x)/a)] + 3*B*f^2*g*n*PolyLog[2, -((d*x)/c)]
3.1.1.3.1 Defintions of rubi rules used
Int[((a_.) + Log[(c_.)*(RFx_)^(p_.)]*(b_.))^(n_.)*(RGx_), x_Symbol] :> With [{u = ExpandIntegrand[(a + b*Log[c*RFx^p])^n, RGx, x]}, Int[u, x] /; SumQ[u ]] /; FreeQ[{a, b, c, p}, x] && RationalFunctionQ[RFx, x] && RationalFuncti onQ[RGx, x] && IGtQ[n, 0]
\[\int \left (f +\frac {g}{x}\right )^{3} \left (A +B \ln \left (e \left (\frac {b x +a}{d x +c}\right )^{n}\right )\right )d x\]
\[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=\int { {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )} {\left (f + \frac {g}{x}\right )}^{3} \,d x } \]
integral((A*f^3*x^3 + 3*A*f^2*g*x^2 + 3*A*f*g^2*x + A*g^3 + (B*f^3*x^3 + 3 *B*f^2*g*x^2 + 3*B*f*g^2*x + B*g^3)*log(e*((b*x + a)/(d*x + c))^n))/x^3, x )
\[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=\int \frac {\left (A + B \log {\left (e \left (\frac {a}{c + d x} + \frac {b x}{c + d x}\right )^{n} \right )}\right ) \left (f x + g\right )^{3}}{x^{3}}\, dx \]
\[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=\int { {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )} {\left (f + \frac {g}{x}\right )}^{3} \,d x } \]
B*f^3*n*(a*log(b*x + a)/b - c*log(d*x + c)/d) - 3*B*f*g^2*n*(b*log(b*x + a )/a - d*log(d*x + c)/c - (b*c - a*d)*log(x)/(a*c)) + 1/2*B*g^3*n*(b^2*log( b*x + a)/a^2 - d^2*log(d*x + c)/c^2 - (b*c - a*d)/(a*c*x) - (b^2*c^2 - a^2 *d^2)*log(x)/(a^2*c^2)) + B*f^3*x*log(e*(b*x/(d*x + c) + a/(d*x + c))^n) + A*f^3*x - 3*B*f^2*g*integrate(-(log((b*x + a)^n) - log((d*x + c)^n) + log (e))/x, x) + 3*A*f^2*g*log(x) - 3*B*f*g^2*log(e*(b*x/(d*x + c) + a/(d*x + c))^n)/x - 3*A*f*g^2/x - 1/2*B*g^3*log(e*(b*x/(d*x + c) + a/(d*x + c))^n)/ x^2 - 1/2*A*g^3/x^2
\[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=\int { {\left (B \log \left (e \left (\frac {b x + a}{d x + c}\right )^{n}\right ) + A\right )} {\left (f + \frac {g}{x}\right )}^{3} \,d x } \]
Timed out. \[ \int \left (f+\frac {g}{x}\right )^3 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right ) \, dx=\int {\left (f+\frac {g}{x}\right )}^3\,\left (A+B\,\ln \left (e\,{\left (\frac {a+b\,x}{c+d\,x}\right )}^n\right )\right ) \,d x \]